package myPack.GMAO.Entity;

import java.io.Serializable;
import java.util.Date;

import javax.persistence.DiscriminatorColumn;
import javax.persistence.DiscriminatorType;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.Inheritance;
import javax.persistence.InheritanceType;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;

@Entity
@Inheritance (strategy=InheritanceType.SINGLE_TABLE)
@DiscriminatorColumn(name="DemandeI_type",discriminatorType=DiscriminatorType.STRING,length=1)
public class DemandeI  implements Serializable{

	@Id @GeneratedValue
	private int idD;
	
    private int desP;
    private Date dateP;
    private boolean arretP;
    
    @ManyToOne @JoinColumn(name="idS")
    private symbtome msymbtome;
    
    @ManyToOne @JoinColumn(name="idE")
    private Etat metat;;

    public DemandeI () {
    }

	public DemandeI(int idD, int desP, Date dateP, boolean arretP,
			symbtome msymbtome, Etat metat) {
		super();
		this.idD = idD;
		this.desP = desP;
		this.dateP = dateP;
		this.arretP = arretP;
		this.msymbtome = msymbtome;
		this.metat = metat;
	}

	public int getIdD() {
		return idD;
	}

	public void setIdD(int idD) {
		this.idD = idD;
	}

	public int getDesP() {
		return desP;
	}

	public void setDesP(int desP) {
		this.desP = desP;
	}

	public Date getDateP() {
		return dateP;
	}

	public void setDateP(Date dateP) {
		this.dateP = dateP;
	}

	public boolean isArretP() {
		return arretP;
	}

	public void setArretP(boolean arretP) {
		this.arretP = arretP;
	}

	public symbtome getMsymbtome() {
		return msymbtome;
	}

	public void setMsymbtome(symbtome msymbtome) {
		this.msymbtome = msymbtome;
	}

	public Etat getMetat() {
		return metat;
	}

	public void setMetat(Etat metat) {
		this.metat = metat;
	}
    
}